/ Mac Power 1997 February
/ macpower199702.bin / AMUG / Programming_7 / Chipmunk Basic 3.5.0 FAT.sit / chipmunk-basic-3.5.0 ƒ / sieve.bas ![]() | < prev | next > |
MacBinary | 1996-07-27 | 1.0 KB | [TEXT/cBaS] |
Confidence | Program | Detection | Match Type | Support |
---|---|---|---|---|
66% | dexvert | GW-BASIC (document/gwBasic) | ext | Supported |
66% | dexvert | GFA-BASIC Atari (other/gfaBASICAtari) | ext | Supported |
10% | dexvert | MacBinary (archive/macBinary) | fallback | Supported |
1% | dexvert | Memotech MTX BASIC source (document/memotechMTXBASICSource) | ext | Unsupported |
1% | dexvert | Amiga BASIC Protected File (other/amigaBASICProtectedFile) | ext | Unsupported |
1% | dexvert | BAS VBDOS Pro 1.0 Source (other/basVBDOSPro10Source) | ext | Unsupported |
1% | dexvert | Visual Basic Tokenized Source (other/visualBasicTokenizedSource) | ext | Unsupported |
1% | dexvert | ZBASIC (other/zbasic) | ext | Unsupported |
1% | dexvert | Text File (text/txt) | fallback | Supported |
100% | file | MacBinary II, inited, Sat Jul 27 11:40:54 1996, modified Sat Jul 27 11:40:54 1996, creator 'cBaS', type ASCII, 432 bytes "sieve.bas" , at 0x230 286 bytes resource | default (weak) | |
99% | file | data | default | |
74% | TrID | Macintosh plain text (MacBinary) | default | |
25% | TrID | MacBinary 2 | default (weak) | |
100% | siegfried | fmt/1762 MacBinary (II) | default | |
100% | lsar | MacBinary | default |
id metadata | |
---|---|
key | value |
macFileType | [TEXT] |
macFileCreator | [cBaS] |
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 00 09 73 69 65 76 65 2e | 62 61 73 00 00 00 00 00 |..sieve.|bas.....|
|00000010| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000020| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000030| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000040| 00 54 45 58 54 63 42 61 | 53 01 00 00 00 00 00 00 |.TEXTcBa|S.......|
|00000050| 00 00 00 00 00 01 b0 00 | 00 01 1e ae 1f e9 06 ae |........|........|
|00000060| 1f e9 06 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000070| 00 00 00 00 00 00 00 00 | 00 00 81 81 ac 9f 00 00 |........|........|
|00000080| 31 30 20 72 65 6d 20 73 | 69 65 76 65 20 36 2f 31 |10 rem s|ieve 6/1|
|00000090| 2f 39 32 20 74 65 73 74 | 0d 32 30 20 6c 6f 6f 70 |/92 test|.20 loop|
|000000a0| 73 20 3d 20 31 0d 33 30 | 20 74 20 3d 20 74 69 6d |s = 1.30| t = tim|
|000000b0| 65 72 0d 34 30 20 64 69 | 6d 20 66 28 38 31 39 34 |er.40 di|m f(8194|
|000000c0| 29 0d 35 30 20 66 6f 72 | 20 6a 20 3d 20 31 20 74 |).50 for| j = 1 t|
|000000d0| 6f 20 6c 6f 6f 70 73 0d | 36 30 20 63 20 3d 20 30 |o loops.|60 c = 0|
|000000e0| 0d 37 30 20 73 20 3d 20 | 38 31 39 31 0d 38 30 20 |.70 s = |8191.80 |
|000000f0| 66 6f 72 20 69 20 3d 20 | 30 20 74 6f 20 73 20 3a |for i = |0 to s :|
|00000100| 20 66 28 69 29 20 3d 20 | 31 20 3a 20 6e 65 78 74 | f(i) = |1 : next|
|00000110| 20 69 0d 39 30 20 66 6f | 72 20 69 20 3d 20 30 20 | i.90 fo|r i = 0 |
|00000120| 74 6f 20 73 0d 31 30 30 | 20 20 20 69 66 20 66 28 |to s.100| if f(|
|00000130| 69 29 20 3d 20 30 20 74 | 68 65 6e 20 67 6f 74 6f |i) = 0 t|hen goto|
|00000140| 20 31 34 30 0d 31 31 30 | 20 20 20 70 20 3d 20 69 | 140.110| p = i|
|00000150| 2b 69 2b 33 0d 31 31 35 | 20 20 20 69 66 20 69 2b |+i+3.115| if i+|
|00000160| 70 20 3e 20 73 20 74 68 | 65 6e 20 31 33 30 0d 31 |p > s th|en 130.1|
|00000170| 32 30 20 20 20 66 6f 72 | 20 6b 20 3d 20 69 2b 70 |20 for| k = i+p|
|00000180| 20 74 6f 20 73 20 73 74 | 65 70 20 70 20 3a 20 66 | to s st|ep p : f|
|00000190| 28 6b 29 20 3d 20 30 20 | 3a 20 6e 65 78 74 20 6b |(k) = 0 |: next k|
|000001a0| 0d 31 33 30 20 20 20 63 | 20 3d 20 63 2b 31 0d 31 |.130 c| = c+1.1|
|000001b0| 34 30 20 6e 65 78 74 20 | 69 0d 31 35 30 20 6e 65 |40 next |i.150 ne|
|000001c0| 78 74 20 6a 0d 31 36 30 | 20 70 72 69 6e 74 20 63 |xt j.160| print c|
|000001d0| 3b 22 20 70 72 69 6d 65 | 73 20 66 6f 75 6e 64 20 |;" prime|s found |
|000001e0| 22 3b 0d 31 37 30 20 74 | 20 3d 20 74 69 6d 65 72 |";.170 t| = timer|
|000001f0| 2d 74 0d 31 38 30 20 70 | 72 69 6e 74 20 6c 6f 6f |-t.180 p|rint loo|
|00000200| 70 73 3b 22 20 74 69 6d | 65 73 20 69 6e 20 22 3b |ps;" tim|es in ";|
|00000210| 0d 31 39 30 20 70 72 69 | 6e 74 20 74 3b 22 20 73 |.190 pri|nt t;" s|
|00000220| 65 63 6f 6e 64 73 22 0d | 32 30 30 20 65 6e 64 0d |econds".|200 end.|
|00000230| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000240| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000250| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000260| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000270| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000280| 00 00 01 00 00 00 01 00 | 00 00 00 00 00 00 00 1e |........|........|
|00000290| 00 cc 05 41 62 6f 75 74 | 05 41 62 6f 75 74 05 41 |...About|.About.A|
|000002a0| 62 6f 75 74 20 50 74 6f | 43 73 74 72 28 72 65 73 |bout Pto|Cstr(res|
|000002b0| 09 73 69 65 76 65 2e 62 | 61 73 02 00 00 00 50 61 |.sieve.b|as....Pa|
|000002c0| 72 74 53 49 54 21 00 00 | 00 00 00 00 00 00 00 02 |rtSIT!..|........|
|000002d0| 00 00 50 61 72 74 53 49 | 54 21 00 00 00 00 00 00 |..PartSI|T!......|
|000002e0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000002f0| 00 00 ae 78 1a ea 00 00 | 00 00 00 00 01 1e 77 53 |...x....|......wS|
|00000300| 65 63 73 3b 0d 20 20 20 | 47 65 74 44 61 74 65 54 |ecs;. |GetDateT|
|00000310| 69 6d 65 28 26 72 61 77 | 53 65 63 73 29 3b 0d 20 |ime(&raw|Secs);. |
|00000320| 20 20 49 55 54 69 6d 65 | 53 74 72 69 6e 67 28 72 | IUTime|String(r|
|00000330| 61 77 53 65 63 73 2c 20 | 31 2c 20 72 65 73 75 6c |awSecs, |1, resul|
|00000340| 74 53 74 72 29 3b 0d 20 | 20 20 50 74 6f 43 73 74 |tStr);. | PtoCst|
|00000350| 72 28 72 65 73 75 6c 74 | 53 74 72 29 3b 0d 7d 0d |r(result|Str);.}.|
|00000360| 0d 69 6e 74 20 6d 6f 75 | 73 65 49 6e 66 6f 28 69 |.int mou|seInfo(i|
|00000370| 6e 74 20 69 29 0d 7b 0d | 20 20 50 6f 69 6e 74 20 |nt i).{.| Point |
|00000380| 00 00 01 00 00 00 01 00 | 00 00 00 00 00 00 00 1e |........|........|
|00000390| 01 2b ce 84 18 fa 00 00 | 00 1c 00 1e ff ff 00 00 |.+......|........|
|000003a0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000003b0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000003c0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000003d0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000003e0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000003f0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
+--------+-------------------------+-------------------------+--------+--------+